package com.grape.grapeboot.controller;

import com.grape.grapeboot.service.UserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * 描述:IndexController 测试控制类
 * @author: myx
 * @date: 2019/7/8 0008
 * Copyright © 2019-grape. All rights reserved.
 */
@RestController
public class IndexController {
    @Autowired
    private UserService userService;

    /**
     * produces = "text/html;charset=UTF-8" 可以解决乱码问题
     * @return
     */
    @RequestMapping(value = "/index", produces = "text/html;charset=UTF-8")
    public String index() {
        return userService.index();
    }
}
